import { useEffect } from "react"
import { baseName } from "../../utils"
import {startApp} from 'wujie'
export const activeRule = (item: any,basename) => {
  
  return item.wujie&&'/wujie'===  location.pathname
}
export const MicroApp = ({name,container, onLoad, entry})=>{
    useEffect(()=>{
        startApp({
            name,
            url: entry,
            el:container
        })
    },[])
  return <div id={container.replace('#','')}/>
}
export default {
  activeRule,
  MicroApp,

}